import java.util.Scanner;

public class text27 {
        public static void main(String[] args) {
            Scanner a = new Scanner(System.in);
            System.out.println("请输入数字,输入0停止程序->");

            int count1 = 0;
            int count2 = 0;
            while(true)
            {
                int num = a.nextInt();

                if(num > 0)
                    count1++;
                if(num < 0)
                    count2++;
                if(num == 0)
                    break;
            }
            System.out.println("正数个数为" + count1);
            System.out.println("负数个数为" + count2);
        }
    }

